package com.ibeifeng.crm.util;

import java.util.Date;





import javax.annotation.Resource;

import org.apache.ibatis.session.SqlSessionFactory;
import org.apache.log4j.Logger;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Repository;

import com.ibeifeng.crm.bean.Log;

@Component
public class LogMessage {
	@Resource
	SqlSessionFactory factory ;
	public boolean optionMessage(String optionUser,String optionType,String optionObject){
		Logger log2 = Logger.getLogger(LogMessage.class);

		Log log=new Log();
		log.setOptionObject(optionObject);
		log.setOptionUser(optionUser);
		log.setOptionType(optionType);
		log.setOptionTime(new Date().toString());
		int i=factory.openSession().insert("com.ibeifeng.crm.log.bean.mapping.LogNS.addLog",log);
		return false;
		
	}
}
